home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1994 February: Tool Chest / Dev.CD Feb 94.toast / New System Software Extensions / QuickDraw™ GX v1.0ß2 / Sample Code / Printing Samples / Printer Drivers… / ImageWriter / ImageWriter.make < prev    next >
Encoding:
Text File  |  1993-09-14  |  5.5 KB  |  179 lines  |  [TEXT/MPS ]

  1. #
  2. #    File:        ImageWriter.make
  3. #
  4. #    Contains:    Makefile for the sample ImageWriter II driver.
  5. #
  6. #    Copyright:    © 1983-1992 by Apple Computer, Inc., all rights reserved.
  7. #
  8. #    Change History (most recent first):
  9. #
  10. #                 9/12/93    dmh        Modified for b2 seed.
  11. #                 4/26/93    dmh        Modified for b1 seed.
  12. #                 2/04/93    dmh        Modified for a5 seed.
  13. #         <5>    10/22/92    DB        Added changes for version control
  14. #
  15. #
  16.  
  17. #======= Point these variables to your interface and library directories =======
  18.  
  19. GraphicsInterfaces    =    'East Terrace:interfaces & libraries:interfaces:'
  20. GXLibrariesSources    =    'East Terrace:interfaces & libraries:graphics libraries:'
  21.  
  22.  
  23. #========== Directories Containing Source and Object Files ==========
  24.  
  25. ObjDir                    =    :Objects:
  26. SrcDir                    =    
  27. DestDir                    =    
  28.  
  29.  
  30. #========== Compiler Options ==========
  31.  
  32. AsmOptions                =    -case obj
  33. RezOptions                =    -i {GraphicsInterfaces} -d SystemSevenOrLater=1
  34. COptions                =    -b2 -i {GraphicsInterfaces}
  35. LinkOptions                =    -ra =resSysHeap,resPurgeable
  36.  
  37. DriverName         = ImageWriter
  38. DriverType         = 'pdvr'
  39. DriverCreator     = 'IWII'
  40. NewSegID        = 0
  41. OldSegID        = 1
  42.  
  43. # Compile and assemble statements
  44. {ObjDir}OldApp.c.o ƒƒ {SrcDir}OldApp.c
  45.     Echo "{DriverName}: Compiling old application"
  46.     C {COptions} -o {ObjDir} {SrcDir}OldApp.c
  47.  
  48. {ObjDir}OldApp.a.o    ƒ     {SrcDir}OldApp.a
  49.     Echo "{DriverName}: Assembling old app jump table"
  50.     Asm {AsmOptions} {MakeJumpTable} {SrcDir}OldApp.a -o {ObjDir}
  51.  
  52. {ObjDir}NewApp.c.o    ƒ {SrcDir}NewApp.c
  53.     Echo "{DriverName}: Compiling new application"
  54.     C {COptions} -o {ObjDir} {SrcDir}NewApp.c
  55.  
  56. {ObjDir}NewApp.a.o    ƒ     {SrcDir}NewApp.a
  57.     Echo "{DriverName}: Assembling new app jump table"
  58.     Asm {AsmOptions} {MakeJumpTable} {SrcDir}NewApp.a -o {ObjDir}
  59.  
  60. {ObjDir}ChooserSupport.c.o    ƒ {SrcDir}ChooserSupport.c
  61.     Echo "{DriverName}: Compiling Chooser support"
  62.     C {COptions} -o {ObjDir} {SrcDir}ChooserSupport.c
  63.  
  64. {ObjDir}ChooserSupport.a.o    ƒ     {SrcDir}ChooserSupport.a
  65.     Echo "{DriverName}: Assembling Chooser support"
  66.     Asm {AsmOptions} {MakeJumpTable} {SrcDir}ChooserSupport.a -o {ObjDir}
  67.  
  68. # Link and Rez statements
  69. {DestDir}{DriverName} ƒƒ {SrcDir}OldApp.r
  70.     Echo "{DriverName}: Rezzing old application"
  71.     Rez {RezOptions} -append -o {DestDir}{DriverName} {SrcDir}OldApp.r
  72.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  73.         
  74. {DestDir}{DriverName} ƒƒ {ObjDir}OldApp.c.o
  75.     Echo "{DriverName}: Linking old application"
  76.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  77.  
  78. "{ObjDir}text library.c.o"        ƒ {GXLibrariesSources}"text library.c"
  79.     Echo "compiling text library.c"
  80.     C {COptions} -o {ObjDir} {GXLibrariesSources}"text library.c"
  81.  
  82. "{ObjDir}picture library.c.o"        ƒ {GXLibrariesSources}"picture library.c"
  83.     Echo "compiling picture library.c"
  84.     C {COptions} -o {ObjDir} {GXLibrariesSources}"picture library.c"
  85.  
  86. "{ObjDir}font library.c.o"        ƒ {GXLibrariesSources}"font library.c"
  87.     Echo "compiling font library.c"
  88.     C {COptions} -o {ObjDir} {GXLibrariesSources}"font library.c"
  89.  
  90. "{ObjDir}color library.c.o"        ƒ {GXLibrariesSources}"color library.c"
  91.     Echo "compiling color library.c"
  92.     C {COptions} -o {ObjDir} {GXLibrariesSources}"color library.c"
  93.  
  94. "{ObjDir}graphics library.c.o"        ƒ {GXLibrariesSources}"graphics library.c"
  95.     Echo "compiling graphics library.c"
  96.     C {COptions} -o {ObjDir} {GXLibrariesSources}"graphics library.c"
  97.  
  98. {DestDir}{DriverName} ƒƒ {SrcDir}NewApp.r
  99.     Echo "{DriverName}: Rezzing new application"
  100.     Rez {RezOptions} -append -o {DestDir}{DriverName} {SrcDir}NewApp.r
  101.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  102.  
  103. {DestDir}{DriverName} ƒƒ                         ∂
  104.     {ObjDir}NewApp.a.o                            ∂
  105.     {ObjDir}NewApp.c.o                            ∂
  106.         "{ObjDir}text library.c.o"                ∂
  107.         "{ObjDir}picture library.c.o"            ∂
  108.         "{ObjDir}font library.c.o"                ∂
  109.         "{ObjDir}color library.c.o"                ∂
  110.         "{ObjDir}graphics library.c.o"
  111.     Echo "{DriverName}: linking new API"
  112.     Link                                        ∂
  113.         {ObjDir}NewApp.a.o                        ∂
  114.         {ObjDir}NewApp.c.o                        ∂
  115.         ∂
  116.         "{ObjDir}text library.c.o"                ∂
  117.         "{ObjDir}picture library.c.o"            ∂
  118.         "{ObjDir}font library.c.o"                ∂
  119.         "{ObjDir}color library.c.o"                ∂
  120.         "{ObjDir}graphics library.c.o"            ∂
  121.         ∂
  122.         "{Libraries}Interface.o"                 ∂
  123.         "{Libraries}Runtime.o"                     ∂
  124.         ∂
  125.         {LinkOptions}                            ∂
  126.         -rt {DriverType}={NewSegID}                ∂
  127.         -c {DriverCreator}                        ∂
  128.         -t {DriverType}                            ∂
  129.         -sg {DriverName}                        ∂
  130.         -m SD_JumpTable                            ∂
  131.         ∂
  132.         -o {DestDir}{DriverName}
  133.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  134.  
  135. {DestDir}{DriverName} ƒƒ                         ∂
  136.     {ObjDir}OldApp.a.o                            ∂
  137.     {ObjDir}OldApp.c.o
  138.     Echo "{DriverName}: linking old API"
  139.     Link                                        ∂
  140.         {ObjDir}OldApp.a.o                        ∂
  141.         {ObjDir}OldApp.c.o                        ∂
  142.         ∂
  143.         "{Libraries}Runtime.o"                     ∂
  144.         ∂
  145.         {LinkOptions}                            ∂
  146.         -rt {DriverType}={OldSegID}                ∂
  147.         -c {DriverCreator}                        ∂
  148.         -t {DriverType}                            ∂
  149.         -sg {DriverName}                        ∂
  150.         -m SD_JumpTable                            ∂
  151.         ∂
  152.         -o {DestDir}{DriverName}
  153.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  154.  
  155. {DestDir}{DriverName} ƒƒ {SrcDir}ChooserSupport.r
  156.     Echo "{DriverName}: Rezzing Chooser resources"
  157.     Rez {RezOptions} -append -o {DestDir}{DriverName} {SrcDir}ChooserSupport.r
  158.     SetFile -a Bi -t {DriverType} -c {DriverCreator} {DestDir}{DriverName}
  159.  
  160. {DestDir}{DriverName} ƒƒ                         ∂
  161.     {ObjDir}ChooserSupport.a.o                    ∂
  162.     {ObjDir}ChooserSupport.c.o
  163.     Echo "{DriverName}: Linking PACK"
  164.     Link                                        ∂
  165.         {ObjDir}ChooserSupport.a.o                ∂
  166.         {ObjDir}ChooserSupport.c.o                ∂
  167.         ∂
  168.         "{Libraries}Interface.o"                 ∂
  169.         ∂
  170.         -rt PACK=-4096                            ∂
  171.         -sg PrintingPACK                        ∂
  172.         -m EntryPoint                            ∂
  173.         ∂
  174.         -o {Targ}
  175.  
  176. {DestDir}{DriverName}    ƒƒ {ObjDir}ChooserSupport.c.o
  177.     Echo "{DriverName}: Linking LDEF"
  178.     Link -w -rt LDEF=-4096 -m LDEF -sg LDEF -o {Targ} {ObjDir}ChooserSupport.c.o
  179.